//
//  UIScrollView+JwCate.h
//  JwPack
//
//  Created by 陈警卫 on 2022/8/24.
//

#import <UIKit/UIKit.h>
#import <MJRefresh/MJRefresh.h>

NS_ASSUME_NONNULL_BEGIN

@interface UIScrollView (JwCate)

/// 添加下拉方法
- (MJRefreshNormalHeader *)jw_mj_headerWithRefreshingBlock:(void(^)(UIScrollView *scrollView))block;

/// 添加上拉方法
- (MJRefreshAutoNormalFooter *)jw_mj_footerWithRefreshingBlock:(void(^)(UIScrollView *scrollView))block;

/// 添加上拉方法
- (MJRefreshAutoNormalFooter *)jw_mj_footerWithRefreshingNoMoreText:(nullable NSString *)text block:(void(^)(UIScrollView *scrollView))block;

- (void)jw_mj_setFooter:(MJRefreshAutoNormalFooter *)footer text:(NSString *)text state:(MJRefreshState)state;

- (void)jw_mj_setFooterNoMore:(BOOL)noMore;

- (void)jw_mj_setHeaderAlphaHidden:(BOOL)hidden;

- (void)jw_mj_setFooterAlphaHidden:(BOOL)hidden;

- (void)jw_mj_removeHeader;

- (void)jw_mj_removeFooter;


- (void)jw_mj_headerBeginRefreshing;

- (void)jw_mj_headerEndRefreshing;

- (void)jw_mj_setHeaderHidden:(BOOL)hidden;

- (BOOL)jw_mj_isHeaderHidden;

- (BOOL)jw_mj_isHeaderRefreshing;


- (void)jw_mj_footerBeginRefreshing;

- (void)jw_mj_footerEndRefreshing;

- (void)jw_mj_setFooterHidden:(BOOL)hidden;

- (BOOL)jw_mj_isFooterHidden;

- (BOOL)jw_mj_isFooterRefreshing;

@end

NS_ASSUME_NONNULL_END
